﻿using System;
using System.Threading.Tasks;
using JetBrains.Annotations;

namespace K9Nano.MultiTenancy
{
    public interface ITenantStore
    {
        [CanBeNull]
        TenantInfo Find(Guid tenantId);

        [CanBeNull]
        TenantInfo Find([NotNull] string tenancyName);

        [CanBeNull]
        ValueTask<TenantInfo> FindAsync(Guid tenantId);

        [CanBeNull]
        ValueTask<TenantInfo> FindAsync([NotNull] string tenancyName);
    }
}